﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true" CodeBehind="CreateAdmin.aspx.cs" Inherits="EmployeeCheckIn.CreateAdmin" %>
<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
    <style type="text/css">
        .style1
        {
            width: 100%;
            
            border-width: 1px;
        }
        .style5
        {        height: 35px;
    }
        .style8
        {
            height: 21px;
            width: 791px;
        }
        .style11
        {
            width: 791px;
        }
        .style12
        {
            width: 1112px;
        }
        .style13
        {
            width: 1112px;
            height: 21px;
        }
        .style14
        {
            width: 791px;
            height: 22px;
        }
        .style15
        {
            width: 1112px;
            height: 22px;
        }
        .style16
        {
            width: 791px;
            height: 26px;
        }
        .style17
        {
            width: 1112px;
            height: 26px;
        }
        </style>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
    <table class="style1" frame="void">
        <tr>
            <td align="left" bgcolor="White" class="style5" colspan="2" 
                style="color: #000000; font-size: large;">
                &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<br />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                
                <asp:Label ID="Label1" runat="server" Font-Size="Large" Text="เพิ่ม Admin" 
                    ForeColor="Black"></asp:Label>
            </td>
        </tr>
        <tr>
            <td class="style11">
                &nbsp;</td>
            <td class="style12">
                &nbsp;</td>
        </tr>
        <tr>
            <td align="right" class="style8" style="font-size: small; color: #000000">
                <span class="RedText">*</span>Username:</td>
            <td class="style13" style="font-size: small; color: #000000">
                <asp:TextBox ID="txtUserName" runat="server" style="margin-left: 0px" 
                    Width="241px"></asp:TextBox>
                <asp:Label ID="lbWarnAddmin" runat="server" ForeColor="Red" 
                    Text="กรุณาป้อนชื่อผู้ดูแล" Visible="False"></asp:Label>
                <asp:Label ID="lbWarnUser" runat="server" ForeColor="Red" 
                    Text="ชื่อนี้มีผู้ใช้แล้ว" Visible="False"></asp:Label>
            </td>
        </tr>
        <tr>
            <td align="right" class="style11" style="font-size: small; color: #000000">
                <span class="RedText">*</span>รหัสผ่าน:</td>
            <td class="style12" style="font-size: small; color: #000000">
                <asp:TextBox ID="txtPassWord" runat="server" TextMode="Password" Width="240px"></asp:TextBox>
                <asp:Label ID="lbWarnNumPass" runat="server" ForeColor="Red" 
                    Text="ต้องไม่น้อยกว่า8ตัวอักษร" Visible="False"></asp:Label>
            </td>
        </tr>
        <tr>
            <td class="style11" align="right" style="font-size: small; color: #000000">
                <span class="RedText">*</span>ยืนยันรหัสผ่าน:</td>
            <td class="style12" style="font-size: small; color: #000000">
                <asp:TextBox ID="txtConfirmPass" runat="server" TextMode="Password" 
                    Width="239px"></asp:TextBox>
                <asp:Label ID="lbConfirmPass" runat="server" EnableTheming="True" 
                    ForeColor="Red" Text="ยืนยันรหัสไม่ถูกต้อง" Visible="False"></asp:Label>
            </td>
        </tr>
        <tr>
            <td align="right" class="style14" style="font-size: small; color: #000000">
                คำนำหน้า:</td>
            <td class="style15" style="font-size: small; color: #000000">
                <asp:RadioButtonList ID="rblTitleAdmin" runat="server" 
                    RepeatDirection="Horizontal">
                    <asp:ListItem Selected="True" Value="1">นาย</asp:ListItem>
                    <asp:ListItem Value="2">นาง</asp:ListItem>
                    <asp:ListItem Value="3">นางสาว</asp:ListItem>
                </asp:RadioButtonList>
            </td>
        </tr>
        <tr>
            <td align="right" class="style11" style="font-size: small; color: #000000">
                <span class="RedText">*</span>ชื่อ:</td>
            <td class="style12" style="font-size: small; color: #000000">
                <asp:TextBox ID="txtFirstName" runat="server" Width="237px"></asp:TextBox>
                <asp:Label ID="lbWarnName" runat="server" EnableTheming="True" 
                    ForeColor="Red" Text="*กรุณากรอกชื่อ" Visible="False"></asp:Label>
            </td>
        </tr>
        <tr>
            <td align="right" class="style16" style="font-size: small; color: #000000">
                <span class="RedText">*</span>นามสกุล:</td>
            <td class="style17" style="font-size: small; color: #000000">
                <asp:TextBox ID="txtLastname" runat="server" Width="236px"></asp:TextBox>
                <asp:Label ID="lbWarnlsn" runat="server" Text="*กรุณากรอกนามสกุล" 
                    ForeColor="Red" Visible="False"></asp:Label>
            </td>
        </tr>
        <tr>
            <td align="right" class="style16" style="font-size: small; color: #000000">
                เบอร์ติดต่อ:</td>
            <td class="style17" style="font-size: small; color: #000000">
                <asp:TextBox ID="txtPhone" runat="server" Width="233px"></asp:TextBox>
                <asp:Label ID="lbConPhone" runat="server" EnableTheming="True" 
                    ForeColor="Red" Text="*กรุณากรอกเบอร์ติดต่อเป็นตัวเลขเท่านั้น" 
                    Visible="False"></asp:Label>
            </td>
        </tr>
        <tr>
            <td align="right" class="style11" style="font-size: small; color: #000000">
                สถานะ:</td>
            <td class="style12" style="font-size: small; color: #000000">
                <asp:DropDownList ID="ddlAdminStatus" runat="server" 
                    DataSourceID="LinqAdminStatus" DataTextField="ADMIN_STATUS_NAME" 
                    DataValueField="ADMIN_STATUS_ID">
                    <asp:ListItem Selected="True" Value="3">กรุณาเลือกสถานะ</asp:ListItem>
                </asp:DropDownList>
                <asp:LinqDataSource ID="LinqAdminStatus" runat="server" 
                    ContextTypeName="EmployeeCheckIn.linqAdminStatusDataContext"
                    Select="new (ADMIN_STATUS_ID, ADMIN_STATUS_NAME)" TableName="TBL_ADMIN_STATUS">
                </asp:LinqDataSource>
            </td>
        </tr>
        <tr>
            <td align="left" class="style11" style="font-size: small; color: #000000">
                &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </td>
            <td class="style12" style="font-size: small; color: #000000">
                <asp:Button ID="btCreatAddminOK" runat="server"  onclick="btCreatAddminOK_Click" 
                    style="margin-left: 32px" Text="บันทึก" Width="50px" />
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                <asp:Button ID="Button3" runat="server" onclick="Button3_Click" Text="รีเซ็ต" 
                    Width="48px" />
            </td>
        </tr>
        <tr>
            <td align="left" class="style11" style="font-size: small; color: #000000">
                &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
                <asp:Button ID="Button2" runat="server" onclick="Button2_Click" 
                    Text="กลับสู่หน้าหลัก" Width="92px" />
            </td>
            <td class="style12" style="font-size: small; color: #000000">
                <asp:HiddenField ID="hdf_AdminID" runat="server" />
            </td>
        </tr>
    </table>
</asp:Content>
